package com.zjj.learn.designmodel.work.mediator;

public class HouseOwner extends Person{
    public HouseOwner(String name) {
        super(name);
    }

    /**
     * 房东发布房源信息
     **/
    @Override
    public void fabuxinxi(String msg) {
        getMediator().publicHouse(msg);
    }

    /**
     * 中介者通知房东有租户想租房了
     * @param message 租户房屋需求
     **/
    public void contact(String message){
        System.out.println("中介通知房东，" + getName() + "：" + message);
    }
}
